package com.jin.vo;

import com.jin.model.Category;
import lombok.Getter;
import lombok.Setter;
import org.springframework.beans.BeanUtils;

//不要导航属性，返回纯净的实体数据VO给前端
@Getter
@Setter
public class CategoriesPureVo {
    private Long id;
    private String name;
    private Boolean isRoot;
    private Long parentId;
    private String img;
    private Long index;

    public CategoriesPureVo(Category category){
        BeanUtils.copyProperties(category,this);
    }
}
